<extend name="Public/base" />
<block name="content">
<div id="content">
	<div id="content-header">
		<div id="breadcrumb">
			<a href="{:U('Index/index')}" title="首页" class="tip-bottom"><i
				class="icon-home"></i> 首页</a> <a href="#" class="current">{$meta_title}</a>
		</div>
	</div>
	<div class="container-fluid">
		<br/>
		<button class="btn btn-info" id="add">新 增</button>
		<button class="btn btn-success ajax-post " url="{:U('setStatus?model=activity&status=1')}" target-form="ids">启 用</button>
		<button class="btn btn-warning ajax-post" url="{:U('setStatus?model=activity&status=0')}" target-form="ids">禁 用</button>
		<button class="confirm btn btn-danger ajax-post" url="{:U('setStatus?model=activity&status=-1')}" target-form="ids">删 除</button>
		<div class="search-form fr cf">
			<div class="sleft">
				<span class="control-group">
					<select class="form-control" style="width: 120px;" name="activity_category_id" id="activity_category_id">
						<option value="请选择活动分类">请选择活动分类</option>
						<volist name="category_list" id="vo">
							<option value="{$vo.activity_category_id}">{$vo.category_name|strip_tags}</option>
						</volist>
					</select>
				</span>
			<!--  	<span class="control-group">
					<select class="form-control" style="width: 120px;" name="marking_status" id="marking_status">
						<option value="请选择审批状态">请选择审批状态</option>
						<option value="0">未审批</option>
						<option value="1">未通过</option>
						<option value="2">通过</option>
						<option value="3">上线</option>
					</select>
				</span>-->
				<input type="text" name="activity_name" class="search-input" value="{:strip_tags(I('activity_name'))}" placeholder="请输入活动名称" style="margin-bottom:0;"><button class="btn btn-info" id="search_button" url="{:U('Activity/index')}"><i class="icon-search icon-white"></i></button>
			</div>
		</div>
		<div class="row-fluid">
			<div class="span12">
				<div class="widget-box">
					<div class="widget-content ">
						<table class="table table-bordered table-striped with-check">
							<thead>
								<tr>
									<th><input type="checkbox" /></th>
									<th>序号</th>
									<th>名称</th>
									<th>类型</th>
							<!-- 		<th>创建人</th>-->									
								<!--  <th>创建时间</th>-->	
									<th>上线时间</th>
									<th>下线时间</th>
								<!-- 	<th>状态</th> -->
									<!-- <th>模版模块</th> -->
									<th>操作</th>
								</tr>
							</thead>
							<tbody>
							<notempty name="_list">
								<volist name="_list" id="vo">
									<tr>
										<td class="taskStatus"><input type="checkbox" value="{$vo.activity_id}" name="ids[]" class="ids"/></td>
										<td class="taskStatus">{$i}</td>
										<td class="taskStatus"><!-- <a href="{:U('config?activity_id='.$vo['activity_id'])}" alt="活动配置" title="活动配置"> -->{$vo.activity_name|htmlspecialchars|msubstr=###,0,10}<!-- </a> --></td>
										<td class="taskStatus">{$vo.is_online_text}</td>
										<td class="taskStatus">{$vo.show_start_time|time_format}</td>
										<td class="taskStatus">{$vo.show_end_time|time_format}</td>
										<td class="taskStatus">
											<a href="{:U('edit?activity_id='.$vo['activity_id'])}"><i class="icon-edit"></i> 编辑</a>
											<a href="{:U('activityVerify?activity_id='.$vo['activity_id'])}"><i class="icon-eye-open"></i> 详细</a>
											<a href="{:U('setStatus?model=activity&ids='.$vo['activity_id'].'&status=-1')}" class="confirm ajax-get"><i class="icon-remove"></i> 删除</a>
										</td>
									</tr>
								</volist>
							<else/>
								<tr>
									<td colspan="11" class="taskStatus"> Oh~亲爱滴,暂时还没有内容! </td>
								</tr>
							</notempty>
							</tbody>
						</table>
						<div class="dataTables_paginate fg-buttonset ui-buttonset fg-buttonset-multi ui-buttonset-multi paging_full_numbers" id="DataTables_Table_0_paginate">
							{$_page}
						</div>
					</div>
				</div>
			</div>
		</div>
	</div>
</div>
<script type="text/javascript">
$(function (){
	//新增跳转页面
	$('#add').click(function(){
		window.location.href="{:U('Activity/add')}";
	});
	set_value("activity_category_id","{:I('activity_category_id','')}");
	set_value("marking_status","{:I('marking_status','')}");
});
//导航高亮
highlight_subnav("{:U('Activity/index')}");
</script>
</block>